home *** CD-ROM | disk | FTP | other *** search
/ Almathera Ten Pack 3: CDPD 3 / Almathera Ten on Ten - Disc 3: CDPD3.iso / scope / 051-075 / scopedisk56 / atoday73 / makescript < prev   
Text File  |  1995-03-19  |  833b  |  33 lines

  1. ;This file is a supplement to an article in Issue 7-3 of Amy Today
  2. .key filename
  3. .DEF filename "ram:temp"
  4.  
  5. if exists <filename>
  6.   ask  "File exists.  Replace it? (Y or N, RETURN=N)"
  7.   ; get response from keyboard, Y=WARN=5, N=0
  8.   if WARN
  9.     ;response was Yes, replace file
  10.     ; resume execution after ENDIF
  11.   ELSE
  12.    ;response was No (or RETURN)
  13.    ; We could omit this ELSE section and fall through to the ENDIF, but
  14.    ;I wanted the example!
  15.    echo "Try another name"
  16.    QUIT 5
  17.    ;quit with error code, since script not written
  18.   ENDIF
  19. ENDIF
  20.     echo "End console input with ctrl-\ ."
  21.     copy * to <filename>
  22.       ;change above line to 'type to <filename>' for ARP use !
  23.     protect <filename> +s
  24.     copy s:makescript.icon to <filename>.info
  25.     ;copies icon to execute script from WB using iconx
  26. ;everything ok
  27. QUIT 0
  28.  
  29.  
  30.  
  31.  
  32.  
  33.